/**
 * Copyright (c) 2016-2019 人人开源 All rights reserved.
 *
 * https://www.renren.io
 *
 * 版权所有，侵权必究！
 */

package com.example.masai.controller;


import com.alibaba.fastjson.JSON;
import com.example.masai.entity.SysUserEntity;
import com.example.masai.service.SysUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;
import java.util.Map;

/**
 * 系统用户
 *
 * @author lee
 */
@RestController
@RequestMapping("/sys/user")
public class SysUserController  {
	@Autowired
	private SysUserService sysUserService;

	/**
	 * 所有用户列表
	 */
	@RequestMapping("/list")
	public String list(@RequestParam Map<String, Object> params){
		List<SysUserEntity> sysUserEntityList = sysUserService.list();

		return JSON.toJSONString(sysUserEntityList);
	}
	
}
